package malus.shaofeng.com.beiwomusic.activity;

import android.app.Activity;
import android.app.Dialog;
import android.support.v7.app.ActionBarActivity;
import android.os.Bundle;
import android.view.Menu;
import android.view.MenuItem;
import android.view.Window;
import android.widget.Button;

import com.lidroid.xutils.ViewUtils;
import com.lidroid.xutils.view.annotation.ContentView;
import com.lidroid.xutils.view.annotation.ViewInject;

import malus.shaofeng.com.beiwomusic.R;
import malus.shaofeng.com.beiwomusic.view.SildingFinishLayout;
import malus.shaofeng.com.beiwomusic.view.Topbar;

@ContentView(R.layout.activity_space_message)
public class SpaceMessageActivity extends Activity
        implements Topbar.onTopbarClickListener, SildingFinishLayout.OnSildingFinishListener {
    @ViewInject(R.id.messageSildingFinishLayout)
    SildingFinishLayout sildingFinishLayout;
    @ViewInject(R.id.button_back)
    Button back;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        requestWindowFeature(Window.FEATURE_NO_TITLE);
        super.onCreate(savedInstanceState);
        ViewUtils.inject(this);

        sildingFinishLayout.setOnSildingFinishListener(this);
    }


    @Override
    public void onBackPressed() {
        finish();
        overridePendingTransition(0,R.anim.trans_slider_out);
    }

    @Override
    public void onLeftButtonClick() {
        finish();
        overridePendingTransition(0,R.anim.trans_slider_out);
    }

    @Override
    public void onRightButtonClick() {

    }

    @Override
    public void onSearchButtonClick() {

    }

    @Override
    public void onSildingFinish() {
        finish();
        overridePendingTransition(0,R.anim.trans_slider_out);
    }
}
